package com.itheima.file;

import java.io.File;

/*
判断方法
 */
public class Demo04 {

    public static void main(String[] args) {
        File file = new File("day12\\ccc.txt");
        //判断是文件夹
        System.out.println(file.isDirectory());
        //判断是文件
        System.out.println(file.isFile());

        File file1 = new File("day12\\abc");
        //判断是文件夹
        System.out.println(file1.isDirectory());
        //判断是文件
        System.out.println(file1.isFile());

    }
}
